package com.zfzs.post.modules.common.repository;

import com.zfzs.post.modules.common.domain.AgentTree;
import org.springframework.data.mongodb.core.query.Query;
import org.springframework.data.mongodb.repository.MongoRepository;

import java.util.List;

/**
 * @author wq
 * @date 2019/10/16 11:37
 * @description
 */
public interface AgentTreeRepository extends MongoRepository<AgentTree, Long> {

    AgentTree findByAgentId(Long agentId);

    List<AgentTree> findByParent(Long agentId);

    List<AgentTree> findByPathRegex(String path);
}
